package com.car.advertising.entity.bean;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * 开发者：LuoYi
 * Time: 2017 16:37 2017/5/4 05
 */

public class AutomobileBrandBean implements Parcelable {

    public String id;
    public String brandCode; //编号
    public String brandName; //名称
    public String carModel; //型号、系列

    public AutomobileBrandBean(String id, String brandCode, String brandName, String carModel) {
        this.id = id;
        this.brandCode = brandCode;
        this.brandName = brandName;
        this.carModel = carModel;
    }

    protected AutomobileBrandBean(Parcel in) {
        id = in.readString();
        brandCode = in.readString();
        brandName = in.readString();
        carModel = in.readString();
    }

    public static final Creator<AutomobileBrandBean> CREATOR = new Creator<AutomobileBrandBean>() {
        @Override
        public AutomobileBrandBean createFromParcel(Parcel in) {
            return new AutomobileBrandBean(in);
        }

        @Override
        public AutomobileBrandBean[] newArray(int size) {
            return new AutomobileBrandBean[size];
        }
    };

    public String getId() {
        return id;
    }

    public String getBrandCode() {
        return brandCode;
    }

    public String getBrandName() {
        return brandName;
    }

    public String getCarModel() {
        return carModel;
    }

    @Override
    public String toString() {
        return "AutomobileBrandBean{" +
                "id='" + id + '\'' +
                ", brandCode='" + brandCode + '\'' +
                ", brandName='" + brandName + '\'' +
                ", carModel='" + carModel + '\'' +
                '}';
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(id);
        dest.writeString(brandCode);
        dest.writeString(brandName);
        dest.writeString(carModel);
    }
}
